Skip to content

Setup GPU testing infrastructure #761

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 5 commits into
base: master
Choose a base branch
from
Open

Conversation

ChrisRackauckas
Copy link
Member

Noted in #759 (comment), GPU is completely untested in ForwardDiff.jl, so this sets up the buildkite pipeline. I setup the backend and all, and just took a few tests from #760 to seed it. The point of this isn't really to be a comprehensive set of GPU tests but rather to update this repo to have the standard tools the other repos have so GPU doesn't regress again/more.

Noted in #759 (comment), GPU is completely untested in ForwardDiff.jl, so this sets up the buildkite pipeline. I setup the backend and all, and just took a few tests from #760 to seed it. The point of this isn't really to be a comprehensive set of GPU tests but rather to update this repo to have the standard tools the other repos have so GPU doesn't regress again/more.
Copy link
Member

@devmotion devmotion left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think these changes are not worth it for these simple tests. The use of JLArrays as in #760 seems much simpler and better suitable for these tests; the main purpose of JLArrays is to perform such simple tests involving GPU arrays. This is also the same GPU test setup that e.g. ChainRules currently uses.

I think using CUDA should only be used in the tests if sufficient testing can't be performed with JLArrays anymore. At this point, I think the setup of the Zygote tests would be preferable if possible - unconditionally load and depend on CUDA in the tests, without messing with the test environment of the Pkg manager, and then skip GPU tests with CUDA unless CUDA.has_cuda().

@ChrisRackauckas
Copy link
Member Author

JLArrays tends to give a lot of false positives because they don't act the same as most GPU arrays, for example the mapreduce behavior can be pretty different along with some of the constructors. It's not necessarily a sufficient test to tell you that CuArrays will actually work. It does work in this case because all of the main problem cases are not hit (from what I can see by eye), but it's not really a correct test for if you want to check for no regressions in CuArrays.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants